home *** CD-ROM | disk | FTP | other *** search
/ NeXT Education Software Sampler 1992 Fall / NeXT Education Software Sampler 1992 Fall.iso / Programming / Source / Weather / Weather.app / Process.h < prev    next >
Text File  |  1991-10-08  |  766b  |  30 lines

  1. #import <objc/Object.h>
  2. #import <stdio.h>
  3.  
  4. #define BUFSIZE 2048
  5.  
  6. @interface Process:Object {
  7.     FILE *fpTo, *fpFrom;
  8.     int from;
  9.     int childPid;
  10.     int masterPty;    // file descriptor for master/slave pty
  11.     int slavePty;
  12.     id delegate;
  13.     int bufferCount;
  14.     char buffer[BUFSIZE];
  15.     SEL action;
  16. }
  17.  
  18. + new:(char *)process delegate:del ;
  19. + new:(char *)process delegate:del andPty:(BOOL)wantsPty andStderr:(BOOL)wantsStderr;
  20. - init:(char *)process delegate:del; // init: andStdErr:YES
  21. - init:(char *)process delegate:del andPty:(BOOL)wantsPty andStderr:(BOOL)wantsStderr;
  22.     
  23. - puts:(char *)s;
  24. - gets:(char *)s :(int)n;
  25. - terminate:sender; // forces the process to terminate (w/ SIGTERM)
  26. - setDelegate:anObject;
  27. - delegate;
  28. - setAction:(SEL)theAction;
  29. @end
  30.